<template>
  <div class="hometopbar">
    <p>
      西安
      <van-icon name="arrow-down" size="4.267vw" color="black" />
    </p>
    <input type="search" value @click="search()" />
    <span>
      <van-icon name="search" size="3.733vw" />烤肉
    </span>
    <van-icon name="ellipsis" size="7.467vw" color="black" />
  </div>
</template>

<script>
export default {
  methods: {
    search() {
      this.$router.push("/hotsearch");
    }
  }
};
</script>

<style lang="scss" scoped>
.hometopbar {
  height: 9.333vw;
  width: 100%;
  font-size: 3.733vw;
  display: flex;
  justify-content: space-between;
  align-items: center;
  line-height: 9.333vw;
  position: relative;
  position: sticky;
  p {
    font-weight: 600;
  }
  input {
    height: 7.467vw;
    outline: none;
    border: none;
    border-radius: 3.733vw;
    box-shadow: 0.267vw 0.267vw 0.8vw 0.267vw gainsboro;
    flex-grow: 1;
    margin: 0 4vw;
  }
  span {
    position: absolute;
    left: 46%;
    color: grey;
    font-size: 3.733vw;
  }
}
</style>